Skip to content

Feature/service tool - #52

Merged
SoleyRan merged 6 commits into
mainfrom
feature/service-tool
Nov 5, 2026
Merged

SoleyRan merged 6 commits into
mainfrom
feature/service-tool

Conversation

@SoleyRan

@SoleyRan SoleyRan commented Nov 5, 2026

Copy link
Copy Markdown
Owner

No description provided.

SoleyRan and others added 6 commits November 4, 2026 10:34
service list --system FILE shows each service the system's nodes
declare, its request and reply types, transport, which components serve
and call it, and whether a server is up, with its instance id and the
age of its newest heartbeat. It reads only the presence topics, so it
creates no client and no reply topic.

service call SERVICE --system FILE sends one request (--data TEXT,
--hex HEX, or none) through an ordinary service::Client and prints the
reply's size, round trip, and bytes, or exits with 1 and the call's
status. Both work on shared memory and, when built with it, FastDDS.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
shm::ReadNewestMessage reads the newest message of a topic from its
segment without attaching, so no writer or reader notices and readers
created later still start after it. On Windows, SharedRegion::OpenReadOnly
now maps an existing region with FILE_MAP_READ instead of returning
Unsupported.

When service list hears no heartbeat on a shm service, it reads the last
presence message left in the segment: a goodbye shows the server as
stopped, and a stale heartbeat as down without a goodbye, with its age.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
tools/portable_fields.{h,cpp} turn typed field values given as text
(bool, i8-i64, u8-u64, f32, f64, string, with [] for a vector or [N]
for an array) into PortableCodec's wire format, and decode a message
back into one text per field, for tools that do not have the message's
C++ type. Decoding fails with DataLoss in the same cases as the codec.

The test compares the bytes with PortableCodec on a struct with every
field type and a nested type, both ways, and covers out-of-range values
and corrupt bytes. It needs only the core library, so it runs in every
build.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
service call --field TYPE:VALUE builds a portable-codec request field by
field, in the order of the type's PortableFields, and --reply-fields
TYPE,... decodes the reply into one line per field. A reply that does
not match the list exits with 1, names the first failing field or the
bytes left over, and prints the reply's bytes. --field cannot be mixed
with --data or --hex.

The topic tool test now strips '\r' from the tool's output, which ends
lines with "\r\n" on Windows, and calls a real PortableCodec service.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
The FastDDS jobs failed with "libtinyxml2.so.10: cannot open shared
object file": ubuntu-latest moved to a newer Ubuntu, but the cache key
used runner.os, which stays "Linux", so a FastDDS built on Ubuntu 24.04
was restored onto a runner with another tinyxml2. Every test linking
FastDDS failed to load, including topic_tool through
puppet_master_topic.

The key now includes the OS ID and version and a hash of the installed
libtinyxml2-dev and libssl-dev versions, so a changed image rebuilds
FastDDS instead of restoring a build that cannot load.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
ubuntu-latest moved past Ubuntu 24.04 and now ships GCC 15, which
cannot build FastDDS 2.14.4: its DDSSQLFilter headers use uint8_t and
uint64_t without including <cstdint>, which GCC 15's standard headers no
longer pull in. With the cache key now tied to the OS release, the job
rebuilt FastDDS from source and failed there.

Pin the FastDDS jobs to ubuntu-24.04, where both FastDDS versions in the
matrix build and pass, and rename them to match. The other jobs stay on
ubuntu-latest, where PuppetMaster itself builds with GCC 15.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@SoleyRan SoleyRan self-assigned this Nov 5, 2026
@SoleyRan
SoleyRan merged commit 702febe into main Nov 5, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant